home *** CD-ROM | disk | FTP | other *** search
-
-
- M A S T E R F I L E 9 6
-
- by Robert B. Cook
-
- Merged with Concatenator by Terry Ricks
-
-
- FENDER'S PREMUMBLE: Terry Ricks of San Antonio TX sent me a revised
- version of MASTERFILE II (published on LS 128 #14) that had the
- Concatenator and the upgrades (from LS 128 #18) merged into the program.
- Now you can easily connect data files to each other without leaving the
- main program. Thanks, Terry! Since searching is one of the most useful
- things you can do with a database program, being able to hook separate data
- files together is important for full searches of files you might prefer to
- keep separate for one reason or another. Now here are the docs for
- MASTERFILE '96 as written by the author, Bob Cook.
-
-
- MASTERFILE is a database management program for the C-128. It's
- memory-based and uses SEQuential files. It will allow you to create your
- own database, choose the field titles, the number and length of the fields
- and print the records in the form of lists or labels.
-
- MASTERFILE can lend itself to many applications. It could, for
- example, be used as an appointment calendar, memo pad, address/phone list,
- disk label maker, etc. The easiest way to learn to use MASTERFILE is to
- create your own data file using the following instructions. It's a good
- idea to print out this text file by using the Print function of the
- LOADSTAR 128 menu.
-
-
- Initialize New File
- -------------------
-
- The first thing you must do is create or initialize your new file.
- Choose Menu option 1, Initialize New File. Any choice other than
- Initialize or Load File From Disk will display an error message to let you
- know that there are no records or file in memory. Let's learn how to use
- MASTERFILE II by creating a database called "friends". It will be an
- address/phone list. Put the highlight bar on Initialize New File and press
- RETURN.
-
- You'll be asked for the number of fields. Enter 7 for this sample.
- Keep in mind that when you create your file, you're defining the structure
- to which all of your records must conform, so you should carefully evaluate
- your choice of fields. It is possible to change the structure of the file
- by using Revise File Structure but if you have a large file, restructuring
- it may cause problem. These will be explained later.
-
- Enter the following information at the prompts:
-
- FIELD TITLE LENGTH
- ------------------------------------
- 1 Last Name 12
- 2 First Name 10
- 3 Street 20
- 4 City 16
- 5 State 2
- 6 ZIP 10
- 7 Phone 12
-
- Note that the ZIP code field allows for nine digits plus a dash, and the
- phone field allows for area codes.
-
- After the last item is entered the approximate amount of record space
- will be displayed. If this amount is acceptable then press Y to return to
- the Main Menu.
-
-
- Add Records
- -----------
-
- Then choose Add Records to File. Enter five or so records into your
- file. You may enter an up arrow (^) whenever you want to repeat the data
- from the previous record. If your friends are all from the same city, this
- will save you plenty of typing.
-
- MASTERFILE will accept most SHIFTed characters, graphics, colons, semi-
- colons and commas. HOME will take you to the beginning of the line. TAB
- or the CRSR keys will move the cursor along the line. INST and DEL work as
- you would expect.
-
- After entering your records, press the ESC key to return to the Main
- Menu. As a matter of fact, almost ANYTIME you want to return to a previous
- menu, press ESCape.
-
-
- Manage Records
- --------------
-
- Next, choose Manage Records. A new menu will be displayed allowing you
- to View, Search, Revise, Delete or Sort your records. Choose View
- Individual records.
-
- Record #1 will be displayed along with a sub-menu. As indicated by the
- menu, you may step through the records in ascending or descending order
- using the + and - keys. The other options are:
-
- 1. Goto - You'll be prompted to enter the record number.
-
- 2. Print - Prints the record currently displayed. Be sure to have your
- printer hooked up and switched on.
-
- 3. Copy - Allows you to copy a whole record to another, existing, record.
- Just enter the number of the record you want the displayed record to be
- copied to.
-
- 4. Revise - Allows you to make modifications to the record currently
- displayed. You will be prompted for the field number that you wish to
- revise.
-
- 5. Delete - Removes the currently displayed record from your file. Press
- X to delete or ESC to escape. If the records were previously sorted then a
- deletion may require a resort. A message will be displayed to make you
- aware of this.
-
- 6. Exit - Takes you back to the Manage Records Menu.
-
- NOTE: If you have a block of records to revise or delete, it's more
- convenient to use the Revise or Delete Selected Records option, which is
- explained below.
-
- Search for Common Items allows you to search through your file to
- locate records with a field containing common data. At the prompts enter
- the field you wish searched, then the type of search, Full, Specific or
- Unequal. Then enter the characters or items you wish to search for.
-
- Full - search the full length of the field and will display all records
- with a match.
-
- Specific - search only that portion of the field you have indicated. For
- example, if you wish to search the phone field for numbers with the calling
- area 456, prefix the search characters with question marks to indicate the
- position of the numbers, ????456. The search will begin with the fifth
- character, disregarding the first four, the area code and the dash. This
- prevents the search from locating telephone numbers with 456 in any other
- position.
-
- Unequal - the exact opposite of the specific search, in that it locates
- records not equal to the selected characters. Indicate the position of the
- characters just as you would in the specific search.
-
- Revise Selected Records and Delete Selected Records allow you to revise
- or delete selected blocks of records. The prompt requests you to enter the
- range of records. If you want to revise or delete only one record, enter
- it only then press RETURN. One thing to remember when revising records,
- the change you enter affects all of the records in the range you've
- selected.
-
- Sort All Records enables you to sort your records by up to three fields.
- Enter the field number for the primary field sort and then the first and
- second subsort field. The subsorts are used when a finer sort is required.
- For instance, when alphabetizing your file by name, the primary field would
- be field 1, Last Name, and the first subsort would be field 2, First Name.
- If both might be identical then the second subsort could be by state or
- ZIP. If a subsort isn't desired, then enter 0 or press RETURN.
-
- Because file data is stored as strings, numbers are sorted according to
- their position within the string, and not by their value. Therefore,
- numbers such as birthdays, (032753), addresses, (050 Main St.), etc. should
- be consistent in length and, if necessary, prefixed with zeroes.
-
-
- Revise File Structure
- ---------------------
-
- If, after using MASTERFILE for a time, you decide that your file
- structure doesn't meet your present needs, you can make the appropriate
- changes quite easily with this option from the Main Menu.
-
- A new menu allows you to Change the field Name or Length, Add or Delete
- a Field, or Reorder the Fields. Choose an option and, at the prompts,
- enter the field number and the change.
-
- When a field or field name is lengthened, or a field is added, you must
- realize that this will reduce the number of available records. To prevent
- the possible loss of some records when the file is almost full, be sure to
- have a current copy of your file saved to disk before you attempt this. You
- only have to worry about this when you have an almost-full file.
-
- Also, when adding a field, (unless a field has been deleted in the
- current file), the file must be saved to complete the addition of the new
- field and then reloaded before you can access the new field.
-
-
- Save File To Disk
- -----------------
-
- Data files have the unique prefix "mf:" automatically added when the
- file is saved to indicate that this is a MASTERFILE data file. A list of
- the MASTERFILE files on the disk will be displayed. Do not enter the "mf:"
- prefix. It will be entered for you.
-
- If there is already a file of the same name as the one you want to
- save, you'll be asked if you would like to rename the existing file. If
- you enter N for No, the file will be scratched. If you enter Y for Yes,
- the file, if it exists, will be renamed with the suffix ":2" to indicate
- that this is a back-up or an old version. Existing files with the suffix
- ":2" will be scratched.
-
-
- Load File From Disk
- -------------------
-
- This works the same as the Save routine.
-
-
- Disk Utilities
- --------------
-
- For your convenience, this module lets you list the directory, rename
- or scratch files, format a disk or change the drive number, and concatenate
- (link) files.
-
- When renaming or scratching files, you are required to indicate what
- type of file you are dealing with; MASTERFILE data (mf:), Report (mr:), or
- Label (ml:).
-
- One of the options, Drive Commands, allows you to Validate, Initialize,
- Read the error channel and select whether you are in 1541 or 1571 mode. See
- your drive manual for disk formatting and drive number info.
-
- NOTE: Do not, under any circumstances, validate a disk with Geos files. A
- disk with Geos files can only be validated from within Geos.
-
- The Concatenator module allows you to put two or more data files
- together as one file. Then you can search or work on the whole thing as
- one file. The directory is shown on the screen so you can easily enter the
- names of the files you want hooked together.
-
-
- Format/Print Records
- --------------------
-
- After you've entered the desired number of files, you'll probably want
- to format them for a report, a list, labels or signs, and then print them
- out. You may also print your records unformatted.
-
-
- Format Reports and Lists
- ------------------------
-
- This takes you to a menu with four options: Define/Review Format, Save
- File to Disk, Load File from Disk and Exit to Format Menu. Choose the
- first option, Define/Review Format.
-
- Your first entry will be the report width. If you're using a standard
- type size of ten characters per inch and paper width of 8 1/2 inches, then
- enter 80. This will give you 80 characters per line with 1/4 inch borders.
- Adjustments may be made in the report width for paper or type size that
- varies from the above.
-
- Next, you may enter up to five title lines, all of which will be
- automatically centered when printed out. Go ahead and type in a title or
- two. Then, indicate the number of columns you want, from 1 to 10. Each
- column and field within a column will be separated by one space, so take
- that into account. Let's use 5.
-
- Column width is determined by the data each column will hold. The five
- columns you specified will hold the following fields: Name, Street, City,
- State and ZIP, and phone. The field lengths are displayed directly above
- the prompt to aid you.
-
- The range shown for column 1 should be (1 to 76), or 80 minus 4 spaces.
- If you add up all the field lengths you'll notice that it totals 83,
- obviously too wide to fit the 76 columns allowed. So we'll reduce the
- column width for some fields.
-
- The first column will hold two fields, First and Last Names. The total
- length of these fields equals 22, but because most names will be less than
- 22 characters, it should be safe to enter 20 for the width. The fields for
- the second column, Street, equal 20. Enter 18 for this width and 13 for
- the city. The last two column widths are 7 and 18. The total of the
- columns will be the maximum 76 spaces.
-
- At times it may be desirable to separate two columns with more than one
- space. If so, add an extra column then set the width to the number of
- spaces desired minus 1.
-
- If there are spaces remaining, the next prompt asks you to specify the
- number of spaces the columns are to be indented. If you use less than the
- maximum number of columns for data then this feature will allow you to
- center the report on the paper. For our example, there are no spaces
- remaining, so this prompt won't be displayed.
-
- Enter the headings for each column at the prompt. You may notice that
- each heading length is restricted to the width of its respective column;
- which means that some headings will have to be abbreviated.
-
- You're allowed five fields per column. Enter the fields in the order
- in which you want them printed. The first column will contain the name
- fields in this order: 2, 1, 0, 0, 0. First name, Last name, then zeroes
- for the rest. Press RETURN after each number. Do the same for each of the
- remaining four colums, entering 3, 0, 0, 0, 0 for the Street field, 4, 0,
- 0, 0, 0 for the City field, 5, 6, 0, 0, 0 for the State and ZIP, and 7, 0,
- 0, 0, 0 for the Phone field.
-
- The last piece of information required is the columns you would like
- totaled, if any. In this case you'll enter a zero. If you had data that
- you wanted totaled, you'd enter the appropriate column number(s) separated
- by commas.
-
- You should now be back at the Format Reports Menu. It would be a good
- idea to save this format now, so choose Save File to Disk from the Reports
- and Lists Menu. If you previously saved your data file, then the filename
- you used will be displayed along with the Report Format prefix "mr:" and
- all you have to do is press RETURN. The prefix indicates that this is a
- MASTERFILE report file and allows you to save the data and format its files
- using a common filename.
-
- Load File from Disk works the same way as Save File from Disk.
-
-
- Format Labels and Signs
- -----------------------
-
- The first option, Define/ Review Format, allows you to define your
- label format just as you defined your report format.
-
- Enter the width and height of the label in inches; the whole number
- followed by a dash then the fraction. Example: 3-1/2. You MUST follow the
- above format. Do not leave any blanks. Enter zeroes wherever a number is
- not used. For our test we'll use a 3 1/2 x 15/16 inch label. Enter 3-1/2
- for the width and 0-15/16 for the height.
-
- Since printers have many different types of print styles, you can
- choose the pitch, or number of characters per inch. For instance, Pica is
- usually 10 cpi, Elite is 12 cpi, Condensed Pica is 17 cpi, and Condensed
- Elite is 20 cpi on a Star NX-1000 printer. This allows you to print longer
- fields on your labels. See your printer manual for the pitches your
- printer allows.
-
- Next, you'll be prompted to enter the number of rows desired. Displayed
- at the top of the screen are the maximum number of rows and characters per
- row available to you, as determined by the pitch you chose. We'll need
- three rows. You may find it easier to add blank rows in order to center
- the rows vertically within the label, rather than adjusting the labels
- within the printer for various label sizes.
-
- If you have a label strip that is more than one label wide, then enter
- the number of labels across. When the labels are printed, a different
- record will printed on each label. Enter 1 for this file.
-
- Enter the fields for each row just as you did when formatting reports.
- For the first row, (First, Last Name), enter 2, 1, 0, the second row,
- (Street), 3, 0, 0, and the last row, (City, State, ZIP), 4, 5 and 6.
-
- And finally, enter the number of spaces to indent each row for
- centering, in this case, 0.
-
- You will return to the Format Labels menu. Save your label format in
- the same manner that you saved your report format. This file will be
- automatically saved with the prefix "ml:" to indicate that it is a
- MASTERFILE label file.
-
- Now let's exit to the Format/Print menu.
-
-
- Configure Printer
- -----------------
-
- Next, let's define your printer functions. This menu will allow you to
- configure up to two printers or interfaces. Pressing Options 1 or 2 will
- cause the arrow to move to the printer chosen. This allows you to have two
- printers hooked up to your computer and to place either one on-line.
-
- We'll configure printer #1, so set the arrow at Printer/Interface #1
- and choose Enter printer Codes. At the prompt, enter information to
- identify the printer, such as its name. Next, enter the device number, 4
- or 5, whichever the printer is set up for. This is usually 4.
-
- At this point, if your printer is not attached or switched on, you'll
- receive an error message. You can switch on your printer to continue. You
- can't enter the printer codes unless the printer is connected and on.
-
- You may configure your printer using up to nine function codes. These
- can be found in your printer manual. You can enter either alpha or numeric
- codes. For example, to start enhanced printing on an Okidata 120, enter
- 27, for chr$(27), as the first code and H as the second. Press RETURN with
- no entry to skip a function.
-
- A submenu will be displayed allowing you to revise the information just
- entered, test the printer by printing a string of characters, or exit.
-
- The printer configuration data is saved along with the MASTERFILE data
- file. If you would like to preserve it, return to the Main Menu and resave
- your file.
-
-
- Print Records Unformatted
- -------------------------
-
- This will print your records unchanged and, if you choose, with the
- record number.
-
-
- Print Reports and List
- ----------------------
-
- This will print your records using the report format you designated.
-
-
- Print Labels and Signs
- ----------------------
-
- This will print your records using the labels format you designated.
-
- Each of the Print options above takes you to another menu with four
- options:
-
- (1) Print All Records - prints all of your records in the format of your
- choice.
-
- (2) Selected Records - allows you to print a consecutive block of records.
- Enter the record numbers separated by a dash.
-
- (3) Records with Common Fields - lets you choose the records you wish to
- print using the search mode as discussed in Managing Your Records.
-
- (4) Exit to Print Menu (or pressing the ESC key) will abort printing and
- return you to the Print menu.
-
- And that takes care of this many-menued program. Any program this
- powerful is going to require your attention but we feel certain that it
- will be worth it. You may want to practice printing out formatted reports
- and labels to the back side of some used printer paper till you get the
- formatting just as you want it.
-
- Robert B. Cook and LOADSTAR hope you enjoy and use MASTERFILE II for
- all your database needs.
-
- \\\\\ R - Run RETURN - Menu \\\\\
-
-